<template>
  <div style="padding: 10px 20px;">
    <tree-table ref="recTree" :list.sync="treeDataSource" @actionFunc="actionFunc" @deleteFunc="deleteFunc" @handlerExpand="handlerExpand" @orderByFunc="orderByFunc"></tree-table>
  </div>
</template>

<script>
  import treeTable from '../../component/tree/tree-table'
  export default {
    name: "menu",
    components: {
      treeTable
    },
    data() {
      return {
        treeDataSource: []
      };
    },
    computed: {

    },
    watch: {

    },
    mounted() {

    },
    methods: {
      orderByFunc(val) {
        alert('排序')

      },
      actionFunc(m) {
        alert('编辑')
      },
      deleteFunc(m) {
        alert('删除')
      },
      handlerExpand(m) {
        console.log('展开/收缩')
        m.isExpand = !m.isExpand
      }
    },
  }
</script>

<style lang='scss' scoped>

</style>
